package com.ruoyi.yyq.api.factory;

import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.common.core.web.page.TableDataInfo;
import com.ruoyi.yyq.api.RemoteCarOrderService;
import com.ruoyi.yyq.api.domain.CarOrder;
import com.ruoyi.yyq.api.domain.CarServiceDetails;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.cloud.openfeign.FallbackFactory;
import org.springframework.stereotype.Component;

@Component
public class RemoteCarOrderFallbackFactory implements FallbackFactory<RemoteCarOrderService> {
	private static final Logger log = LoggerFactory.getLogger(RemoteCarOrderFallbackFactory.class);
	@Override
	public RemoteCarOrderService create(Throwable cause) {
		log.error("服务调用失败:{}", cause.getMessage());
		return new RemoteCarOrderService(){


			@Override
			public TableDataInfo getlist(String source, CarOrder carOrder) {
				return null;
			}

			@Override
			public AjaxResult getadd(String source, CarOrder carOrder) {
				return null;
			}

			@Override
			public AjaxResult getedit(String source, CarOrder carOrder) {
				return null;
			}

			@Override
			public AjaxResult getremove(String source, Long[] ids) {
				return null;
			}

			@Override
			public AjaxResult getcode(String source, String verificationCode) {
				return null;
			}


		};
	}
}
